<%@ page contentType="text/html; charset=utf-8" %>
<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<script type="text/javascript">
<!--
function toLogin()
{
  //以下为按钮点击事件的逻辑。注意这里要重新打开窗口
  //否则后面跳转到QQ登录，授权页面时会直接缩小当前浏览器的窗口，而不是打开新窗口
  /*
  var A=window.open("http://openapi.qzone.qq.com/oauth/show?which=ConfirmPage&display=pc&client_id=100567639&redirect_uri=www.zhi-qingchun.com&scope=get_user_info&response_type=code&redirect_uri=www.zhi-qingchun.com&client_id=100567639","TencentLogin", 
  "width=450,height=320,menubar=0,scrollbars=1,
  resizable=1,status=1,titlebar=0,toolbar=0,location=1");
  */
  location = "https://graph.qq.com/oauth2.0/authorize?response_type=code&client_id=100567639&redirect_uri=www.zhi-qingchun.com/ZhiQingchun/qqLogin.html&scope="
} 
//-->
</script>
		<div id="header">
		<div class="center-box">
			<a href="default.html">Zhi-QingChun</a>
			<span id="nav"><a href="showCategory.html">分类</a></span>
			<span id="user-zone">
			<!-- 
				<img src="${path }/img/connect_logo_qq.png" onclick="toLogin();" />
			 -->
			<c:if test="${sessionScope.user eq null }">
				<a href="login.html">登录</a>
				<span>|</span>
				<a href="register.html">注册</a>
			</c:if>
			<c:if test="${sessionScope.user != null }">
				<a href="user.html?id=${sessionScope.user.id }">${sessionScope.user.usr }的空间</a>
				<span>|</span>
				<a href="logout.html">退出</a>
			</c:if>
			</span>
		</div>
		</div>
